﻿@*
    Configuration Server

    Provides a single configuration point for the several instances (development,
    staging, testing, production, etc.) for web sites

    Includes ideas and code from all over the internet. Specially, stacktrace, msdn, github.

    Copyright (C) 2014 by Jaime Espinosa <jaimeespinosa60@gmail.com>

    The MIT License (MIT)

    Copyright (c) 2014 jaime espinosa

    Permission is hereby granted, free of charge, to any person obtaining a copy
    of this software and associated documentation files (the "Software"), to deal
    in the Software without restriction, including without limitation the rights
    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
    copies of the Software, and to permit persons to whom the Software is
    furnished to do so, subject to the following conditions:

    The above copyright notice and this permission notice shall be included in all
    copies or substantial portions of the Software.

    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
    SOFTWARE.

    @author Jaime Espinosa <jaimeespinosa60@gmail.com>
    @package configuracion
    @version 0.1
*@
@using Microsoft.AspNet.Identity
<!DOCTYPE html>
<html lang="en">

<head>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Configuration Platform</title>

    <!-- Bootstrap Core CSS -->
    <link href="/content/css/bootstrap.min.css" rel="stylesheet">

    <!-- Custom CSS -->
    <link href="/content/css/sb-admin.css" rel="stylesheet">

    <!-- Morris Charts CSS -->
    <link href="/content/css/plugins/morris.css" rel="stylesheet">

    <!-- Custom Fonts -->
    <link href="/content/fonts/font-awesome-4.1.0/css/font-awesome.min.css" rel="stylesheet" type="text/css">

    <!-- jQuery Version 1.11.0 -->
    <script src="/content/js/jquery-1.11.0.js"></script>

    <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
    <!--[if lt IE 9]>
        <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
        <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->

</head>

<body>

    <div id="wrapper">

        <!-- Navigation -->
        <nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
            <!-- Brand and toggle get grouped for better mobile display -->
            <div class="navbar-header">
                <a class="navbar-brand" href="/">Configuration Service</a>
            </div>
            <!-- Top Menu Items -->
            <ul class="nav navbar-right top-nav">
                <li class="dropdown">
                    @if (Request.IsAuthenticated)
                    {
                        <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-user"></i> @User.Identity.GetUserName() <b class="caret"></b></a>
                    }
                    else
                    {
                        <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-user"></i> Log in <b class="caret"></b></a>
                    }
                    <ul class="dropdown-menu">
                        @Html.Partial("_LoginPartial")
                    </ul>
                </li>
            </ul>
            <!-- Sidebar Menu Items - These collapse to the responsive navigation menu on small screens -->
            <div class="collapse navbar-collapse navbar-ex1-collapse">
                <ul class="nav navbar-nav side-nav">
                    @if (Request.IsAuthenticated)
                    {
                        <li @Html.Raw(ViewBag.section == "dashboard" ? "class='active'" : "")>
                            <a href="/home/dashboard"><i class="fa fa-fw fa-dashboard"></i> Dashboard</a>
                        </li>
                        <li>
                            <a href="/owner/list"><i class="fa fa-fw fa-building-o"></i> Owners</a>
                        </li>
                        <li>
                            <a href="/Bundle/list"><i class="fa fa-fw fa-table"></i> Bundles</a>
                        </li>                        
                        <li>
                            <a href="javascript:;" data-toggle="collapse" data-target="#demo"><i class="fa fa-fw fa-arrows-v"></i> Test <i class="fa fa-fw fa-caret-down"></i></a>
                            <ul id="demo" class="collapse">
                                <li>
                                    <a href="/consume/keyForBundleDirect">Test directly</a>
                                </li>
                                <li>
                                    <a href="/consume/keyForBundleLibrary">Test library</a>
                                </li>
                            </ul>
                        </li>

                    }
                </ul>
            </div>
            <!-- /.navbar-collapse -->
        </nav>

        <div id="page-wrapper">

            <div class="container-fluid">
                @RenderBody()
                <div class="embed-responsive" style="color:red">
                    @ViewBag.Exception
                </div>
            </div>
            <!-- /.container-fluid -->

        </div>
        <!-- /#page-wrapper -->

    </div>

    @RenderSection("scripts", required: false)
    <!-- /#wrapper -->
    <!-- Bootstrap Core JavaScript -->
    <script src="/content/js/bootstrap.min.js"></script>

    <!-- Morris Charts JavaScript -->
    <script src="/content/js/plugins/morris/raphael.min.js"></script>
    <script src="/content/js/plugins/morris/morris.min.js"></script>
    <script src="/content/js/plugins/morris/morris-data.js"></script>

</body>

</html>
